package org.dromara.app.domain.vo;

import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import org.dromara.app.domain.AppUserMessage;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;

import java.io.Serial;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * App端用户消息读取记录视图对象 app_user_message
 *
 * @author ruoyi
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = AppUserMessage.class)
public class AppUserMessageVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @ExcelProperty(value = "主键")
    private Long id;

    /**
     * App用户ID
     */
    @ExcelProperty(value = "App用户ID")
    private Long userId;

    /**
     * 消息ID
     */
    @ExcelProperty(value = "消息ID")
    private Long messageId;

    /**
     * 是否已读（0未读 1已读）
     */
    @ExcelProperty(value = "是否已读", converter = ExcelDictConvert.class)
    @ExcelDictFormat(dictType = "sys_yes_no")
    private String isRead;

    /**
     * 读取时间
     */
    @ExcelProperty(value = "读取时间")
    private LocalDateTime readTime;

    /**
     * 创建时间
     */
    @ExcelProperty(value = "创建时间")
    private LocalDateTime createTime;

}